package com.lw.smartdevice.controller;

import com.lw.smartdevice.dto.R;
import com.lw.smartdevice.service.SysMenuService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author Administrator
 * @version 1.0
 * @description:
 * @date 2022/3/27 17:46
 */
@RestController
@RequestMapping("/menus")
public class SysMenuController {

    private SysMenuService sysMenuService;

    @Autowired
    public void setSysMenuService(SysMenuService sysMenuService) {
        this.sysMenuService = sysMenuService;
    }

    @GetMapping("/menus")
    public R findAllLeftMenu(){
        return R.setOK(sysMenuService.findAllLeftMenu());
    }
}
